Skip to content

Fix sidebar click#40

Merged
ScriptSmith merged 2 commits into
mainfrom
fix-sidebar-click
May 31, 2026
Merged

Fix sidebar click#40
ScriptSmith merged 2 commits into
mainfrom
fix-sidebar-click

Conversation

@ScriptSmith
Copy link
Copy Markdown
Owner

No description provided.

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 31, 2026

Greptile Summary

This PR refactors conversation list items in both ConversationList and Sidebar to use an absolutely-positioned overlay button (absolute inset-0) as the full-row click target, replacing the previous flex button that only covered the text area. Interactive siblings (drag handle, dropdown trigger) get relative z-10 so they paint above the overlay and receive pointer events first.

  • ConversationList.tsx: The select button is converted to an absolute inset-0 overlay; content moves into an aria-hidden sibling div; the aria-label is enriched with message count and model count; the dropdown trigger gains relative z-10.
  • Sidebar.tsx: The same overlay pattern is applied to both SortablePinnedItem (with the drag handle already getting relative z-10) and the inline conversation item inside the main conversation tree.

Confidence Score: 5/5

Safe to merge — changes are purely presentational/structural and don't touch data, routing, or state management logic.

All three click-target refactors follow the same pattern consistently: overlay button covers the row, interactive siblings (drag handle, dropdown trigger) are lifted with relative z-10 so they receive pointer events before the overlay. Event propagation and stacking-context behaviour are handled correctly throughout.

No files require special attention.

Important Files Changed

Filename Overview
ui/src/components/ConversationList/ConversationList.tsx Select button replaced with full-row overlay; aria-label enriched with message/model counts; dropdown trigger gets z-10 lift; logic is correct.
ui/src/components/Sidebar/Sidebar.tsx Same overlay pattern applied to SortablePinnedItem and inline conversation rows; drag handle and dropdown triggers correctly promoted to z-10; no regressions found.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A["Pointer Event on Row"] --> B{Which element is topmost?}
    B -->|"Drag handle area\n(relative z-10)"| C["Drag handle div\nstopPropagation → DnD kit"]
    B -->|"Dropdown trigger area\n(relative z-10)"| D["Dropdown trigger button\nOpens context menu"]
    B -->|"Anywhere else on row\n(overlay button, no z-index)"| E["Overlay button\nabsolute inset-0"]
    E --> F["onSelect / handleSelectConversation"]
    F --> G["Navigate to conversation"]
Loading

Reviews (3): Last reviewed commit: "Review fixes" | Re-trigger Greptile

Comment thread ui/src/components/ConversationList/ConversationList.tsx
@ScriptSmith
Copy link
Copy Markdown
Owner Author

@greptile-apps

@ScriptSmith ScriptSmith merged commit 83c0d17 into main May 31, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant